function [X, Y, Chunksize] = deploy_h5file(h5file, solver_mode, net_model, weights, forward_batch_size)
global DeployH5_LogFile
hPfrintf = mycaffe.getPrintf(DeployH5_LogFile);

if nargin < 5
	forward_batch_size = 200;
end

h5 = hdf5info(h5file);
Chunksize = h5.GroupHierarchy.Datasets.Chunksize;

hPfrintf('H5 file is reading, please waiting ...\n')
X = hdf5read(h5.GroupHierarchy.Datasets(1));
X = mycaffe.caffe_batch(X, net_model, weights, solver_mode, 'test', forward_batch_size);

Y = hdf5read(h5.GroupHierarchy.Datasets(2));
% Y = mycaffe.caffe_batch(Y, net_model, weights, solver_mode, 'test', forward_batch_size);

% psnr = srimg.psnr(squeeze(X), squeeze(Y(:, :, :,1:5)), 4)
